home *** CD-ROM | disk | FTP | other *** search
/ CD-ROM Magazine 28 Bonus / CDRomMagazine-SoftKey-ArtPassion-FrenchVersion-Win31Mac.bin / data / cnbalex.dir / 00147_Script_UTILITY HANDLERS < prev    next >
Text File  |  1996-06-10  |  636b  |  32 lines

  1. on setPuppets spriteList,state
  2.   
  3.   repeat with i = 1 to count(spriteList)
  4.     puppetSprite getpos(spriteList,i), state -- get a VALUE by referring to a POSITION in the list
  5.   end repeat
  6. end
  7.  
  8.  
  9. on setSpriteVisibility spriteList,state
  10.   repeat with i = 1 to count(spriteList)
  11.     set the visible of sprite value(getAt(spriteList,i)) to getAt(state,i)
  12.   end repeat
  13.   updateStage
  14.   
  15. end
  16.  
  17.  
  18. on inList aList,anElement
  19.   
  20.   set inList = FALSE
  21.   
  22.   repeat with i = 1 to count(aList)
  23.     if anElement = getAt(aList,i) then
  24.       set inList = TRUE
  25.       exit repeat
  26.     end if
  27.   end repeat
  28.   
  29.   return inList
  30.   
  31. end
  32.